<template>
	<tm-fullView>
		<template  v-slot:default="{ info }">
			<view class="grey text " :class="$tm.vx.state().tmVuetify.black ? 'grey-darken-5 bk' : ''"
				:style="{ minHeight: info.height + 'px' }">
				<tm-menubars title="反馈bug或者意见"   :showback="false"></tm-menubars>
				
				<tm-sheet>
					<tm-form @submit="subit">
						<tm-input v-model="req.email" name="email" :padding="[0,12]" required title="联系邮箱" :vertical="true" input-type="text"></tm-input>
						<view style="height: 24rpx;"></view>
						<tm-input v-model="req.word" name="word" :padding="[0,12]" required title="提交事项原由" :height="110" :vertical="true" input-type="textarea" :maxlength="215"></tm-input>
						<view class="py-32">
							<tm-button navtie-type="form" dense block>提交反馈</tm-button>
						</view>
					</tm-form>
				</tm-sheet>
				<view class="flex-center">
					<tm-images :width="60"  src="static/logo_great.png"></tm-images>
					<view class="px-24"></view>
					<tm-images :width="200"  src="https://jx2d.cn/yuwuimages/tmui120.3-small.png?id=6888"></tm-images>
				</view>
				<view class="py-24 px-0 text-size-xs text-grey-lighten-1 text mx-32 text-align-center">
					本UI经过细致打磨，并且还在不断的细化中，让它成为高效率、高颜值、高覆盖率的组件库，需要各方努力贡献。
					<view>请不要盗版，可免费使用。</view>
					<view class=" text-weight-b" :class="[`text-${$tm.vx.state().tmVuetify.color || 'primary'}`]">
						用户Q群：
						<text selectable>18593916</text>
					</view>
				</view>
				<tm-dialog v-model="show" title="反馈提醒" content="感谢你的提交,我会优先答复邮件反馈.也尽请加入Q群更好的反馈:18593916,加群答案:tm-vuetify"></tm-dialog>
			</view>
			
		</template>
	</tm-fullView>
</template>

<script>
	import tmSheet from "@/tm-vuetify/components/tm-sheet/tm-sheet.vue"
	import tmFullView from "@/tm-vuetify/components/tm-fullView/tm-fullView.vue"
	import tmMenubars from "@/tm-vuetify/components/tm-menubars/tm-menubars.vue"
	import tmInput from "@/tm-vuetify/components/tm-input/tm-input.vue"
	import tmButton from "@/tm-vuetify/components/tm-button/tm-button.vue"
	import tmForm from "@/tm-vuetify/components/tm-form/tm-form.vue"
	import tmDialog from "@/tm-vuetify/components/tm-dialog/tm-dialog.vue"
	import tmImages from "@/tm-vuetify/components/tm-images/tm-images.vue"
	
	
	export default {
		components:{tmSheet,tmFullView,tmMenubars,tmInput,tmButton,tmForm,tmDialog,tmImages},

		data() {
			return {
				req:{
					email:'',
					word:''
				},
				show:false,
			};
		},
		methods: {
			async subit(e) {
				
				if(!e) return;
				if(!uni.$tm.test.email(e.email)){
					uni.$tm.toast("请输入合法邮箱。")
					return;
				}
				if(uni.$tm.test.empty(e.word)){
					uni.$tm.toast("内容不能为空")
					return;
				}
				
				
			}
		},
	}
</script>

<style lang="scss">

</style>
